

var frequencyEnum = {  
    1: "Daily",
    2: "Weekly",
    3: "SemiMonthly",
    4: "Monthly",
    5: "Quarterly"
}

var collection = db.getSiblingDB("ClientPlatform").FtpClientReport
collection.find({Frequency: { $type: 16 }}).forEach(function(item){

    item.Frequency = frequencyEnum[item.Frequency];

    collection.save(item);
})

